﻿using System;
using System.Xml.Serialization;
using TiPort.TiEntityObjects;
using TI;

namespace TiEntityObject.Contract
{
    public class ContractFinances
    {
        public Int64 ID { get; set; }

        [XmlElement("financeSource")]
        public string FinanceSource { get; set; }

        [XmlElement("budget")]
        [LinkObjectAttribute(ChildFieldName = "code", IsDictionaryValue = false, ParentFieldName = "BudgetID")]
        public Budget Budget { get; set; }

        public string BudgetID { get; set; }

        [XmlElement("budgetary")]        
        [LinkObjectAttribute(ChildFieldName = "ID", IsPartialObject = true, ParentFieldName = "ID")]
        public Budgetary Budgetary { get; set; }


        [XmlElement("extrabudgetary")]        
        [LinkObjectAttribute(ChildFieldName = "ID", IsPartialObject = true, ParentFieldName = "ID")]
        public ExtraBudgetary ExtraBudgetary { get; set; }

        
        [XmlElement("order")]
        [LinkObjectAttribute(ChildFieldName = "ID", IsPartialObject = true, ParentFieldName = "ID")]
        public ContractOrder ContractOrder { get; set; }

    }
}
